// File: tests/bbs_test.rs
#[cfg(test)]
mod tests {
    use super::*;
    use crate::bbs::{post::BbsPost, gitee_sync::GiteeManualSync};

    const REAL_POST: &str = include_str!("../tests/real_data/ibugce_post.md");

    #[test]
    fn test_real_post_workflow() {
        let post = BbsPost::new(
            "RUST项目实战营规划汇报".to_string(),
            REAL_POST.to_string(),
            "@yuandj".to_string()
        );
        
        // 验证模板生成
        let template = GiteeManualSync::generate_template(&post);
        assert!(template.contains("MOCHAIN BBS"));
        assert!(template.contains(&post.author));
        
        // 验证哈希计算
        let hash = calculate_content_hash(REAL_POST);
        assert_eq!(hash.len(), 64);
    }
}
